<template>
  <div class="outer">
    {{list}}
    <h1>App</h1>
    <List @atguigu="getListData" />
  </div>
</template>

<script>
import _ from "lodash";
import List from "./components/List";
export default {
  name: "App",
  data() {
    return {
      list: [],
    };
  },

  components: {
    List,
  },

  methods: {
    getListData(list) {
        // 深拷贝
      this.list = _.cloneDeep(list);
    },
  },
};
</script>

<style>
.outer {
  height: 400px;
  background-color: aqua;
}
</style>